Expose a native polling method for both authorization and order contexts - #10
Expose a native polling method for both authorization and order contexts#10microalps wants to merge 6 commits into
Conversation
|
Thanks, this is a good idea so worth pursing a little more. The way we currently use this library is from a higher level consumer which has retries but building it into the library consistently would be good. Things it needs:
|
|
I thought about your second point. However, to implement this we must change the retryCount to a retryTimeout (say, two minutes) so that ACME server doesn't hang the process by giving a retry in an unexpected range (e.g. 1 day). Using retryCount * retryDelay doesn't account for latency of the request itself. Is that acceptable to you as this would be a behavior change to the Generate/Download methods? |
|
Yes, an overall retry/operation timeout would be easier for users to understand as well. Internally we probably care about how often we retry, but users don't. |
|
Due to it being a public API (which, FYI, was changed in post 3.3.3 to have a different default of 3 retries) this is now a breaking change. I tried to make a backward-compatible implementation, but it isn't exactly going to follow the 3 retry logic. Some examples (theoretically):
I guess if this is merged it should be bumped as v3.4.0 |
|
@webprofusion-chrisc what is needed to merge? Are you testing against an actual CA? |
|
Thanks, it's really just waiting for me to find time to properly review it but just looking over the diff there are still several places where a literal value of seconds (3, 15 etc) is specified and we need to make these configurable. |
I believe the hard-coded values were there before. The new explicit methods for waiting are fully configurable, it's specifically if you |
This PR adds a polling step to the ACME client flow to better handle asynchronous processing/status transitions.
What changed
Why
Notes
Excerpt from RFC 8555